package demo;

/**
 * 构建者实例 - 2
 *
 * @author GongXincheng
 * @since 2019-09-19 21:04
 */
public class ConcreteBuilder_2 implements Builder {

    private Product product = new Product();

    @Override
    public void BuildPartA() {
        product.getList().add("component Y");
    }

    @Override
    public void BuildPartB() {
        product.getList().add("component Z");
    }

    @Override
    public Product getProduct() {
        return product;
    }
}
